Skip to content

Chore(ClipboardCopy): add tooltip to play icon#11583

Merged
nicolethoen merged 3 commits intopatternfly:mainfrom
Mash707:adding-tooltip-to-playicon
Mar 4, 2025
Merged

Chore(ClipboardCopy): add tooltip to play icon#11583
nicolethoen merged 3 commits intopatternfly:mainfrom
Mash707:adding-tooltip-to-playicon

Conversation

@Mash707
Copy link
Copy Markdown
Contributor

@Mash707 Mash707 commented Mar 1, 2025

Closes #11385

@patternfly-build
Copy link
Copy Markdown
Collaborator

patternfly-build commented Mar 1, 2025

Copy link
Copy Markdown
Contributor

@thatblindgeye thatblindgeye left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition to the file comments below:

  • The issue linked in your original comment should point to #11385
  • The Codeblock examples just need a similar update
  • Can you update the original commit message and PR title to a chore rather than a feature?

</ClipboardCopy>
);
export const ClipboardCopyInlineCompactWithAdditionalAction: React.FunctionComponent = () => {
const [showSuccessContent, setShowSuccessContent] = React.useState(false);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slight nitpick, but maybe [isRunning, setIsRunning] for the state so that it's aligned closer to the intent of the state.

variant="inline-compact"
additionalActions={
<ClipboardCopyAction>
<Tooltip aria="none" aria-live="polite" content={showSuccessContent ? doneRunText : runText}>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Depends on the intent of the example when originally added, but for now let's add the onTooltipHidden callback to set the state back to false. That way when the tooltip disappears and you retrigger it, it'll say "Run in web terminal" again rather than staying as "Running in web terminal".

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, will make the necessary changes.

@Mash707 Mash707 force-pushed the adding-tooltip-to-playicon branch from c4e2cd7 to d1d9604 Compare March 3, 2025 14:07
@Mash707 Mash707 changed the title feat(ClipboardCopy): add tooltip to play icon Chore(ClipboardCopy): add tooltip to play icon Mar 3, 2025
@Mash707 Mash707 requested a review from thatblindgeye March 3, 2025 19:14
@Mash707
Copy link
Copy Markdown
Contributor Author

Mash707 commented Mar 3, 2025

If possible, Can I get details regarding why Integration tests (0) is failing?

@Mash707 Mash707 force-pushed the adding-tooltip-to-playicon branch from 14e8615 to cc05938 Compare March 3, 2025 19:27
@Mash707 Mash707 force-pushed the adding-tooltip-to-playicon branch from cc05938 to 14c0bb3 Compare March 3, 2025 19:46
@Mash707
Copy link
Copy Markdown
Contributor Author

Mash707 commented Mar 3, 2025

If possible, Can I get details regarding why Integration tests (0) is failing?

Nevermind had some rebasing issues.

@nicolethoen nicolethoen merged commit ae6a7a7 into patternfly:main Mar 4, 2025
13 checks passed
@Mash707 Mash707 deleted the adding-tooltip-to-playicon branch March 6, 2025 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ClipboardCopy/CodeBlock - Additional action in example missing a tooltip

4 participants